<!doctype html>
<html lang="en"  ng-app='xiaohu'>
<head>
    <meta charset="UTF-8">
    <title>支乎</title>
    <link rel="stylesheet" href="/laravel54/public/node_modules/normalize-css/normalize.css">
    <link rel="stylesheet" href="/laravel54/public/css/base.css">
    <script src="/laravel54/public/node_modules/jquery/dist/jquery.js"></script>
    <script src="/laravel54/public/node_modules/angular/angular.js"></script>
    <script src="/laravel54/public/node_modules/angular-ui-router/release/angular-ui-router.js"></script>
    <script src="/laravel54/public/js/base.js"></script>
    <script src="/laravel54/public/js/user.js"></script>
    <script src="/laravel54/public/js/common.js"></script>
    <script src="/laravel54/public/js/question.js"></script>
    <script src="/laravel54/public/js/answer.js"></script>
</head>
<body ng-controller="BaseController" user-id="{{ session('user_id') }}">
<div class="navbar clearfix">
    <div class="container">
        <div class="fl">
            <div ui-sref="home" class="navbar-item brand">知乎</div>
            <form id="quick_ask" action="" ng-controller="QuestionAddController" ng-submit="Question.go_add_question()">
                <div class="navbar-item">
                    <input title="" type="text" name="" id="" ng-model="Question.new_question.title">
                </div>
                <div class="navbar-item">
                    <button>提问</button>
                </div>
            </form>
        </div>
        <div class="fr">
            <a ui-sref="home" class="navbar-item">首页</a>
            @if(is_logged_in())
                <a ui-sref="login" class="navbar-item">{{session('username')}}</a>
                <a href="{{url('/api/logout')}}" class="navbar-item">登出</a>
            @else
                <a ui-sref="login" class="navbar-item">登录</a>
                <a ui-sref="signup" class="navbar-item">注册</a>
            @endif
        </div>
    </div>
</div>
<div class="page">
    <div ui-view=""></div>
</div>

</body>
</html>